package co.crossoft.domain;

import java.io.Serializable;
import java.util.Date;

public class ResourceTypeResource implements Serializable {
    private String handle;

    private String resourceFk;

    private String resourceTypeFk;

    private Date dateUpdate;

    private static final long serialVersionUID = 1L;

    public String getHandle() {
        return handle;
    }

    public void setHandle(String handle) {
        this.handle = handle == null ? null : handle.trim();
    }

    public String getResourceFk() {
        return resourceFk;
    }

    public void setResourceFk(String resourceFk) {
        this.resourceFk = resourceFk == null ? null : resourceFk.trim();
    }

    public String getResourceTypeFk() {
        return resourceTypeFk;
    }

    public void setResourceTypeFk(String resourceTypeFk) {
        this.resourceTypeFk = resourceTypeFk == null ? null : resourceTypeFk.trim();
    }

    public Date getDateUpdate() {
        return dateUpdate;
    }

    public void setDateUpdate(Date dateUpdate) {
        this.dateUpdate = dateUpdate;
    }

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        ResourceTypeResource other = (ResourceTypeResource) that;
        return (this.getHandle() == null ? other.getHandle() == null : this.getHandle().equals(other.getHandle()))
                && (this.getResourceFk() == null ? other.getResourceFk() == null : this.getResourceFk().equals(other.getResourceFk()))
                && (this.getResourceTypeFk() == null ? other.getResourceTypeFk() == null : this.getResourceTypeFk().equals(other.getResourceTypeFk()))
                && (this.getDateUpdate() == null ? other.getDateUpdate() == null : this.getDateUpdate().equals(other.getDateUpdate()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getHandle() == null) ? 0 : getHandle().hashCode());
        result = prime * result + ((getResourceFk() == null) ? 0 : getResourceFk().hashCode());
        result = prime * result + ((getResourceTypeFk() == null) ? 0 : getResourceTypeFk().hashCode());
        result = prime * result + ((getDateUpdate() == null) ? 0 : getDateUpdate().hashCode());
        return result;
    }
}